package speed;

public class ArrayCopy {
	public static void main(String[] args) {
		int arr1[] = {0,1,2};
		int arr2[] = new int[arr1.length];
//		arr1 = arr2      这样会直接改变arr1的内容，用for循环进行赋值。
		for(int i=0;i < arr1.length;i++) {
			arr2[i] = arr1[i];
		}
		
		for(int i=0;i<arr2.length;i++) {
			System.out.println(arr2[i]);
		}
	}

}
